package com.admin.controller;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.servlet.ModelAndView;

import com.member.dao.MemberDao;
import com.member.domain.MemberCommand;

@Controller
public class AdminPageController {
	
	@Autowired
	private MemberDao memberDao;
	
	@RequestMapping(value="/admin/adminPage.do",method=RequestMethod.GET)
	public ModelAndView process(@RequestParam("id")String id){
		MemberCommand memberCommand = memberDao.getMember(id);
		return new ModelAndView("adminPage","memberCommand",memberCommand);
	}
}
